<div id="table-links">
    <a id="locations" href="/goals/locations"></a>
    <a id="armors" href="/goals/armors"></a>
    <a id="weapons" href="/goals/weapons"></a>
</div>
<div id="filters">
    <form method="post" action="/goals/processfilters">
        Select location type:<br/>
        <select name="typefilter" onchange="this.form.submit()">
            <option value="Cave">Cave</option>
            <option value="City">City</option>
            <option value="Town">Town</option>
            <option value="Grotto">Grotto</option>
            <option value="Imperial Fort">Imperial Fort</option>
            <option value="Ashlander Camp">Ashlander Camp</option>
        </select>
    </form>
</div>
<table id="locations">
    <th id="foundit">Found it!</th>
    <th id="location"></th>
    <th id="type">Type</th>
    <form action="/goals/processlocations" method="post">
        <?php foreach($this->locations as $location):?>
        <tr>
            <td id="checkbox"><input type="checkbox" class="styled" name="checkedlocations[]" value="<?php echo $this->escape($location->id)?>"/></td>
            <td id="data"><?php echo $this->escape($location->name)?></td>
            <td id="data"><?php echo $this->escape($location->type)?></td>
        </tr>
        <?php endforeach; ?>
        <td colspan="2">
        <?php for($i = 1; $i <= $this->numberofpages; $i++): ?>
            <a href="/goals/locations?page=<?php echo $i; ?>" ><?php echo $i; ?></a>
        <?php endfor; ?>
        </td>
        <td><input type="submit" value="" id="submitbtn"/></td>
    </form>
</table>
<table id="locations">
    <th id="location"></th>
    <th id="type">Type</th>
    <?php foreach ($this->locationsfound as $locationfound):?>
    <tr>
        <td id="data"><?php echo $this->escape($locationfound->name)?></td>
        <td id="data"><?php echo $this->escape($locationfound->type)?></td>
    </tr>
    <?php endforeach; ?>
</table>